/**
 * 
 */
package fr.upvm.lem3.vm3d.ui.swing.menu;

import java.awt.BorderLayout;
import java.awt.Color;
import java.awt.Component;
import java.awt.Dimension;
import java.awt.Font;
import java.awt.GridLayout;
import java.awt.Point;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.ItemEvent;
import java.awt.event.ItemListener;

import javax.swing.BorderFactory;
import javax.swing.Box;
import javax.swing.BoxLayout;
import javax.swing.JButton;
import javax.swing.JCheckBox;
import javax.swing.JDialog;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JTextField;
import javax.swing.border.EtchedBorder;
import javax.swing.border.LineBorder;
/**
 *  A final dialog class to give information about this software
 * 	@author Nougouapi
 * 	Datum: 14.02.2012
 */
public final class Info {

	/**
	 * 
	 */
	private static final long serialVersionUID = 9177038639598961741L;
	private static String INFO_MESSAGE= "<html>Intership vm3d<br>" +
										"Version 1.00<br>" +
										"&copy; 2012 by Guy Nougouapi & Dr. Benoit Beausir & Dr. Lionel Germain<br>" +
										"Powered by Dr. Benoit Beausir & Dr. Lionel Germain <br>" +
										"Thanks to UDL, UFR MIM</html>";
	private static String TITLE = "About Vm3d";
	static JPanel msgPanel;
	
	/**
	 * call to prompt Information about this software
	 * @param frame
	 */
	public static void showInfoMsg(JFrame frame){
		JOptionPane.showMessageDialog (frame, getMsgPanel(), TITLE, JOptionPane.INFORMATION_MESSAGE);
	}
	/**
	 *   
	 * @return
	 */
	private static JPanel getMsgPanel(){
		 if(msgPanel == null){
			 msgPanel = new JPanel();
			 msgPanel.add(new JLabel(INFO_MESSAGE));
			 msgPanel.setBorder(BorderFactory.createMatteBorder(3, 3, 3, 3, new Color(125, 125, 125)));
		 }
		 return msgPanel;
	 }

}
